package com.sunyard.dal.mapper;

import com.sunyard.dal.bo.operator.OperatorAuditQueryBO;
import com.sunyard.dal.dto.OperatorCopyDTO;
import com.sunyard.dal.dto.OperatorCopyExportDTO;
import com.sunyard.dal.entity.OperatorCopy;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface OperatorCopyMapper {

    int insert(OperatorCopy operatorCopy);

    int insertSelective(OperatorCopy record);

    //用户名是否重复
    int existOpName(String opName);

    //根据id查询用户
    OperatorCopy getOperatorCopyById(String opId);

    //根据机构ID查询用户
    List<OperatorCopy> getListOperatorCopyByOrgId(String orgId);

    int countOperatorCopyByRoleId(String roleId);

    List<OperatorCopyDTO> getOperatorCopyListByPage(Map<String, Object> queryMap);

    List<OperatorCopyExportDTO> operatorAuditExport(OperatorAuditQueryBO operatorAuditQueryBO);

    OperatorCopy getOperatorCopyByAuditId(String auditId);

    int updateOperatorCopy(OperatorCopy operatorCopy);

    OperatorCopyDTO getOperatorCopyDTOByAuditId(String auditId);

    int maxAuditSn(String opId);

    //用户名是否重复
    int existOpId(String opId);

    int countByOpId(@Param("opId") String opId);

    OperatorCopy getOperatorCopyByIdUnlock(String opId);

    //获取首页待审核用户数量
    int getOperatorAuditCount(@Param("orgIds") List<String> orgIds);
}
